package sshremote;


public class Test {

    public static void main(String[] args) {
        String linuxIP = "192.168.11.121";
        String usrName = "root";
        String passwd = "123456";

        RemoteExecuteCommand rec = new RemoteExecuteCommand(linuxIP, usrName, passwd);
        // 执行命令
        try {
            System.out.println(rec.execute("ifconfig"));

            System.out.println(rec.execute("env"));
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
